package com.sightp.tujubeacon;

import android.app.Application;

import com.palmaplus.nagrand.core.Engine;
import com.sightp.tujubeacon.utils.Constants;
import com.sightp.tujubeacon.utils.FileUtilsTools;

/**
 * Created by Xu XiaoYang on 2017/7/26.
 */

public class MyApplication extends Application {

    @Override
    public void onCreate() {
        super.onCreate();

        // copy assets Nagrand/lua to SD Card Nagrand/lua folder
        FileUtilsTools.copyDirToSDCardFromAsserts(this, "Nagrand/lua", "font");
        FileUtilsTools.copyDirToSDCardFromAsserts(this, "Nagrand/lua", "Nagrand/lua");

        // init Engine
        Engine instance = Engine.getInstance();
        instance.startWithLicense(Constants.AppKey, this);
    }
}
